package com.tyk.bookstore.front.product.model.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.io.Serial;
import java.io.Serializable;
import java.time.LocalDateTime;

@Schema(name = "Classification", description = "用户详情")
@TableName("classification")
@Data
public class ClassificationDo implements Serializable {
    @Serial
    private static final long serialVersionUID = 1;

    @Schema(description = "ID")
    @TableId(value = "id")
    private Long id;

    @Schema(description = "级别[1一级，2二级，3三级]")
    @TableField("level")
    private Byte level;

    @Schema(description = "父级ID")
    @TableField("parent_id")
    private Long parentId;

    @Schema(description = "名称")
    @TableField("`name`")
    private String name;

    @Schema(description = "创建时间")
    @TableField(value = "create_time")
    private LocalDateTime createTime;

    @Schema(description = "更新时间")
    @TableField(value = "update_time")
    private LocalDateTime updateTime;
}
